home *** CD-ROM | disk | FTP | other *** search
/ Magnum One / Magnum One (Mid-American Digital) (Disc Manufacturing).iso / d20 / msgq160s.arc / BMG.H < prev    next >
Text File  |  1991-10-26  |  614b  |  32 lines

  1. /*
  2.  * BMG.H - Searching functions
  3.  *
  4.  * Msged/Q message editor for QuickBBS  Copyright 1990 by P.J. Muller
  5.  *
  6.  */
  7.  
  8. /*
  9.  *    bmg.h ->    Boyer-Moore-Gosper search definitions
  10.  *
  11.  *    see bmg.c for documentation
  12.  */
  13.  
  14. #define    bmgMAXPAT    64        /*  max pattern length    */
  15.  
  16. typedef struct
  17.     {
  18. #ifdef BMGSEARCH
  19.     char    delta[256];        /*  ASCII only deltas    */
  20. #endif
  21.     char    pat[bmgMAXPAT + 1];    /*  the pattern        */
  22.     char    ignore;            /*  ignore case flag    */
  23.     }
  24.     bmgARG;
  25.  
  26. void bmgCompile(char *s, bmgARG *pattern, int ignore_case);
  27. int bmgSearch(char *buffer, int buflen, bmgARG *pattern);
  28.  
  29. /*
  30.  *    END of bmg.h
  31.  */
  32.